
#import <React/RCTBridgeModule.h>
#import <React/RCTEventEmitter.h>
#import <MPNebulaAdapter/MPNebulaAdapterInterface.h>
#import "RNMpaasWrapper.h"

@interface RNMpaas : RCTEventEmitter

//处理小程序调用rn方法
- (void)tinyHandler:(NSDictionary *)data context:(PSDContext *)context callbackid:(NSString *)callbackid;
//建立通道消息
- (void)tinyChannelHandler:(NSDictionary *)data context:(PSDContext *)context channelId:(NSString *)channelId;

- (void)startWebView:(NSString *)title url:(NSString *)url userAgent:(NSString *)userAgent options:(NSDictionary *)options;

//回调小程序
- (void)callbackTiny:(NSString *)callbackid result:(NSDictionary *)result;
//向小程序发送事件
@property (nonatomic, copy) void (^sendEvent)(NSString *eventName, id data);

//调整 ViewController 位置 by index
- (void)bringViewControllerToIndex:(NSUInteger)to fromIndex:(NSUInteger)from;
//置顶 ViewController by class
- (void)bringViewControllerToFrontWithClass:(Class)class;
//置底 ViewController by class
- (void)bringViewControllerToBackWithClass:(Class)class;

@end
  
